import static org.junit.Assert.*;

import org.junit.Test;

/**
 * @author Beruke Zeleke
 */
public class enoughWeightTest
{
	@Test
	public void test()
	{
		ItemBag bag = new ItemBag();
		
		assertEquals(true, bag.enoughWeight("food"));
		bag.addFood(bag.getMaxWeight() / bag.foodW);
		assertEquals(false, bag.enoughWeight("food"));
		bag.setQuantity(new int[]{ 0, 0, 0, 0, 0, 0 });
		
		assertEquals(true, bag.enoughWeight("water"));
		bag.addWater(bag.getMaxWeight() / bag.waterW);
		assertEquals(false, bag.enoughWeight("water"));
		bag.setQuantity(new int[]{ 0, 0, 0, 0, 0, 0 });
		
		assertEquals(true, bag.enoughWeight("repair"));
		bag.addRepair(bag.getMaxWeight() / bag.repairW);
		assertEquals(false, bag.enoughWeight("repair"));
		bag.setQuantity(new int[]{ 0, 0, 0, 0, 0, 0 });
		
		assertEquals(true, bag.enoughWeight("medicine"));
		bag.addMedicine(bag.getMaxWeight() / bag.medicineW);
		assertEquals(false, bag.enoughWeight("medicine"));
		bag.setQuantity(new int[]{ 0, 0, 0, 0, 0, 0 });
	}
}